package com.daxue.business.controller;

import com.daxue.business.producer.MsgProducer;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/test")
public class TestSendA {

    @Autowired
    MsgProducer producer;

    @GetMapping("/a")
    public String testSend() {
        producer.sendMsg("a","你好啊");
        return "ok_a";
    }

    @GetMapping("/b")
    public String testSendB() {
        producer.sendMsg("b","你好啊");
        return "ok_b";
    }


}
